import { _decorator, Component, director, Node } from 'cc';
import { ModuleCenter } from './Module/ModuleCenter';
const { ccclass, property } = _decorator;

@ccclass('Entrance')
export abstract class Entrance extends Component {

    protected async onLoad() {
        ModuleCenter.initialize(this);

    }

    protected async start() {
        await this.onLoadBundles();
        this.onEnter();
    }

    protected update(dt: number): void {
        ModuleCenter.update(dt);
    }

    protected lateUpdate(dt: number): void {
        ModuleCenter.lateUpdate(dt);
    }
    
    
    protected  abstract onLoadBundles();
    protected  abstract onEnter();
}


